home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Tech Arsenal 1
/
Tech Arsenal (Arsenal Computer).ISO
/
tek-02
/
tptsr.zip
/
TSR.DEM
< prev
next >
Wrap
Text File
|
1990-06-25
|
4KB
|
124 lines
program demo; { See tsr.doc and tsr.skl for details. }
uses crt, dos, tsr, crtplus, calendar;
{$M 4096,4096,4096}
{$F+}
procedure Startup;
begin
clrscr;
writeln('Shareware TSR unit demo');
writeln('Copyright John W. Small 1990');
writeln('PSW, P.O. Box 10072, McLean VA 22102 8072');
writeln;
writeln('Press <Alt> C to popup calendar; ESC to exit.');
writeln('Cursor keys change months; page keys change years.');
writeln;
writeln('At the command line prompt type: ');
writeln;
writeln(' tsr -r to remove the TSR from memory,');
writeln(' tsr -d to deactivate the TSR in memory,');
writeln(' tsr -a to activate TSR in memory,');
writeln(' tsr -m to force monochrome display,');
writeln(' tsr -c to force color display,');
writeln(' tsr -p to popup calendar.');
writeln;
writeln('This shareware TSR demo can be popped up only 3');
writeln('times without registering. Type "tsr -r" at the');
writeln('command line prompt for registration information.');
end;
procedure Popup;
var ftw : FramedTextWindow;
y, m, d, dow : word;
begin
if not CrtPlus.TxtScr.IsTextMode then
exit;
ftw.window(5,5,28,14);
if TSRcolor then begin
TextColor(BLACK);
TextBackground(CYAN)
end
else begin
TextColor(BLACK);
TextBackground(LIGHTGRAY)
end;
ftw.frame(TextAttr,svsh);
cursor.off;
clrscr;
GetDate(y,m,d,dow);
WriteCalendar(y,m);
while crtplus.readkey <> ESC do begin
case char(lo(crtplus.asciiScan)) of
#0: case char(hi(crtplus.asciiScan)) of
LArr, UpArr: begin
if m > 1 then
dec(m)
else begin
m := 12;
dec(y)
end;
if y <= 1752 then begin
y := 1752;
m := 10
end
end;
RArr, DnArr:
if m < 12 then
inc(m)
else begin
m := 1;
inc(y)
end;
PgUp: begin
dec(y);
if y <= 1752 then begin
y := 1752;
m := 10
end
end;
PgDn: inc(y);
Home: GetDate(y,m,d,dow);
end;
end;
clrscr;
WriteCalendar(y,m)
end;
ftw.done
end;
procedure Wrapup;
begin
clrscr;
writeln('To register the TSR unit sent $20 to:');
writeln;
writeln(' PSW / Power SoftWare');
writeln(' P.O. Box 10072');
writeln(' McLean, VA 22102 8072');
writeln;
writeln('Upon registration you will be sent the source code');
writeln('for tsr.pas and cmdln.pas on a 5.25" DOS diskette.');
writeln;
writeln('Check your favorite BBS for other shareware tools for TP 5.5 from PSW:');
writeln;
writeln(' crtplus $20 keyboard, cursor, and popup window');
writeln(' enhancements to crt unit, 100+ page manual');
writeln(' omouse $7 mouse object, primitive paint demo');
writeln(' graphtxt $7 text file device driver for graphic');
writeln(' modes, any font, any justification.');
writeln(' tpflex $20 flexlist object, 100+ page manual');
writeln(' generic stack-queue-list-array');
writeln(' tppan $7 panscroller object, generic pan-scroll');
writeln(' for editors, pick lists, spreadsheets, etc.');
end;
procedure OptionComm(optCh: char; argSeg, argOfs : word);
begin
end;
{$F-}
begin
MakeTSR('','TSR Demo',46,8,Startup,Popup,Wrapup,OptionComm);
end.